package com.example.design.bilibili.observer;

public class BaiduSite implements Observer{

    private float temperature;

    private float pressure;

    private float humidity;

    @Override
    public void update(float temperature, float pressure, float hunidity) {
        this.temperature = temperature;
        this.pressure = pressure;
        this.humidity = hunidity;
        display();
    }

    public void display(){
        System.out.println("***百度 temperature is "+temperature+"***");
        System.out.println("***百度 pressure is "+pressure+"***");
        System.out.println("***百度 humidity is "+humidity+"***");
    }
}
